<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>品牌管理</title>
    <meta content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no" name="viewport">

    <link rel="shortcut icon" href="favicon.ico">
    <link rel="stylesheet" href="../css/plugins/bootstrap/css/bootstrap.css">
    <script src="../js/jQuery/jquery-2.2.3.min.js"></script>
    <script src="../css/plugins/angularjs/angular.min.js"></script>
    <script src="../css/plugins/bootstrap/js/bootstrap.js"></script>

    <script>
        var app=angular.module('aisile', []);//定义模块
        app.controller('brandController' ,function($scope,$http){
            //读取列表数据绑定到表单中
            $scope.findAll=function(){
                $http.get('../record/getrecord').success(
                    function(response){
                        console.log(response);
                        $scope.list=response;
                    }
                );
            }
        });
    </script>



</head>
<body class="hold-transition skin-red sidebar-mini" ng-app="aisile"   ng-controller="brandController" ng-init="findAll()">
<!-- .box-body -->
<div class="box-header with-border">
    <h3 class="box-title">记录</h3>
</div>

<div class="box-body">

    <!-- 数据表格 -->
    <div class="table-box">

        <!--工具栏-->
        <div class="pull-left">
            <div class="form-group form-inline">
                <div class="btn-group">
                </div>
            </div>
        </div>
        <div class="box-tools pull-right">
            <div class="has-feedback">

            </div>
        </div>
        <!--工具栏/-->
        <button type="button"
                class="btn  btn-info" onclick="exportUser()">
            <i class="glyphicon glyphicon-download-alt" aria-hidden="true"></i>&nbsp;&nbsp;&nbsp;导出用户
        </button>
        <!--数据列表-->
        <table id="dataList" class="table table-bordered table-striped table-hover dataTable">
            <thead>
            <tr>
                <th class="sorting">测试开始时间</th>
                <th class="sorting_asc">学生姓名</th>
                <th class="sorting">学生性别</th>
                <th class="sorting">学生年龄</th>
                <th class="sorting">学生得分</th>
                <th class="sorting">测评结束时间</th>
            </tr>
            </thead>
            <tbody>
            <tr ng-repeat="pojo in list">
                <td>{{pojo.starttime}}</td>
                <td>{{pojo.name}}</td>
                <td>{{pojo.sex}}</td>
                <td>{{pojo.age}}</td>
                <td>{{pojo.sum}}</td>
                <td>{{pojo.stoptime}}</td>
            </tr>
            </tbody>
        </table>
        <!--数据列表/-->


    </div>
    <!-- 数据表格 /-->




</div>
<!-- /.box-body -->

<!-- 编辑窗口 -->
<div class="modal fade" id="editModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-dialog" >
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                <h3 id="myModalLabel">品牌编辑</h3>
            </div>
            <div class="modal-body">
                <table class="table table-bordered table-striped"  width="800px">
                    <tr>
                        <td>品牌名称</td>
                        <td><input  class="form-control" placeholder="品牌名称" >  </td>
                    </tr>
                    <tr>
                        <td>首字母</td>
                        <td><input  class="form-control" placeholder="首字母">  </td>
                    </tr>
                </table>
            </div>
            <div class="modal-footer">
                <button class="btn btn-success" data-dismiss="modal" aria-hidden="true">保存</button>
                <button class="btn btn-default" data-dismiss="modal" aria-hidden="true">关闭</button>
            </div>
        </div>
    </div>
</div>

</body>
<script>
    function exportUser(){
        location.href = "/record/export";
    }
</script>
</html>